FROM golang:latest

RUN go env -w GO111MODULE=on
RUN go env -w GOPROXY=https://goproxy.cn,direct
# 安装vim
RUN apt-get update
RUN apt-get install -y vim

WORKDIR $GOPATH/src/ginblog

COPY . $GOPATH/src/ginblog

RUN go build .

EXPOSE 9000

ENTRYPOINT ["./ginblog"]